import { ExtractPropTypes, Ref } from 'vue'

export type AccordionItem = {
  label: string
  value: string | number
  disabled?: boolean
  children?: AccordionItem[]
  active?: boolean
  open?: boolean
}

export const accordionProps = {
  data: {
    type: Array<AccordionItem>,
    default: []
  },
  width: {
    type: Number
  },
  height: {
    type: Number
  }
}

export type AccordionProps = ExtractPropTypes<typeof accordionProps>

export const accordionEmit = ['click']

export type AccordionEmit = typeof accordionEmit
